package com.mall.pojo;

import cn.hutool.core.util.DesensitizedUtil;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.mall.note.Sensitize;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serial;
import java.io.Serializable;

/**
 *
 * @author xiao-chen
 * @since 2023-04-20
 */
@Data
@TableName("t_admin")
@AllArgsConstructor
@NoArgsConstructor
public class Admin implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(value = "id")
    private Long id;

    /**
     * 用户名
     */
    @Sensitize(type = DesensitizedUtil.DesensitizedType.CHINESE_NAME)
    private String username;

    /**
     * 密码
     */
    @Sensitize(type = DesensitizedUtil.DesensitizedType.PASSWORD)
    private String password;

    /**
     * 是否超级管理员
     */
    private Integer isSuper;


}
